﻿<navigation:Page 
           xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" 
           xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" 
           xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
           xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
           xmlns:ViewModels="clr-namespace:AR.ViewModel"
           xmlns:navigation="clr-namespace:System.Windows.Controls;assembly=System.Windows.Controls.Navigation"
           xmlns:sdk="http://schemas.microsoft.com/winfx/2006/xaml/presentation/sdk" 
          x:Class="AR.Views.LoginPage"
           mc:Ignorable="d"
           d:DesignWidth="1000" d:DesignHeight="800"
           Title="Atos Recrutement">
    <navigation:Page.Resources>
        <ViewModels:LoginPageViewModel x:Key="viewModel" />
    </navigation:Page.Resources>
    <Grid x:Name="LayoutRoot" Width="810"  DataContext="{Binding Source={StaticResource viewModel}}">
        <Grid.RowDefinitions>
            <RowDefinition Height="1*"/>
            <RowDefinition Height="7*"/>
        </Grid.RowDefinitions>
        <Grid.ColumnDefinitions>
            <ColumnDefinition />
            <ColumnDefinition Width="40" />
            <ColumnDefinition  />
        </Grid.ColumnDefinitions>
        <Border BorderBrush="{StaticResource AtosBlue}"   CornerRadius="1.5" BorderThickness="1.5" HorizontalAlignment="Left" Height="300" Margin="10,76,0,0" Grid.Row="1" VerticalAlignment="Top" Width="375" Grid.Column="2">
            <Grid Margin="0,0,-1,0">
                <Grid.ColumnDefinitions>
                    <ColumnDefinition Width="1*"/>
                    <ColumnDefinition Width="3*"/>
                    <ColumnDefinition Width="1*"/>
                </Grid.ColumnDefinitions>
                <Grid.RowDefinitions>
                    <RowDefinition Height="1*"/>
                    <RowDefinition Height="1*"/>
                    <RowDefinition Height="1*"/>
                    <RowDefinition Height="1*"/>
                    <RowDefinition Height="1*"/>
                    <RowDefinition Height="1*"/>
                    <RowDefinition Height="1*"/>
                </Grid.RowDefinitions>
                <sdk:Label Content=" Réservé aux candidats" Grid.Column="0" Foreground="White" Grid.ColumnSpan="3" Background="{StaticResource AtosBlue}" Grid.Row="0" FontSize="18" FontWeight="Bold"/>
                <sdk:Label Content="Code entretien technique" Grid.Column="1" Grid.Row="2" HorizontalAlignment="Center"/>
                <Button Content="Passer l'entretien" Grid.Column="1" Grid.Row="4" Margin="25,5,25,5" Command="{Binding PasserEntretienCommand}" CommandParameter="{Binding Text, ElementName=textcode}"/>
                <TextBox Grid.Column="1" x:Name="textcode" Grid.Row="3" Margin="35,5,35,5" />
                <sdk:Label Content="le code entré est erroné ou expiré !" Visibility="{Binding InvalidCodeVisible}" HorizontalAlignment="Left" Height="28" Margin="65,10,0,0" Grid.Row="6" VerticalAlignment="Top" Foreground="Red" Grid.ColumnSpan="3" Width="317"/>

            </Grid>
        </Border>
        <Border BorderBrush="{StaticResource AtosBlue}"  CornerRadius="1.5" BorderThickness="1.5" HorizontalAlignment="Left" Height="300" Margin="10,76,0,0" Grid.Row="1" VerticalAlignment="Top" Width="375">
            <Grid Margin="0,0,-1,0">
                <Grid.ColumnDefinitions>
                    <ColumnDefinition Width="1*"/>
                    <ColumnDefinition Width="3*"/>
                    <ColumnDefinition Width="1*"/>
                </Grid.ColumnDefinitions>
                <Grid.RowDefinitions>
                    <RowDefinition Height="1*"/>
                    <RowDefinition Height="1*"/>
                    <RowDefinition Height="1*"/>
                    <RowDefinition Height="1*"/>
                    <RowDefinition Height="1*"/>
                    <RowDefinition Height="1*"/>
                    <RowDefinition Height="1*"/>
                </Grid.RowDefinitions>
                <sdk:Label Content="  Réservé aux employés ATOS"  Foreground="White" Grid.Column="0" Grid.ColumnSpan="3" Background="{StaticResource AtosBlue}" Grid.Row="0" FontSize="18" FontWeight="Bold"/>

                <sdk:Label Content="Identifiant " Grid.Column="0" Grid.ColumnSpan="2" Grid.Row="2" Margin="10,0,0,0" />
                <TextBox Grid.Column="1" Grid.Row="2" Margin="25,5,25,5" Text="{Binding Username,Mode= TwoWay}"/>
                <sdk:Label Content="Mot de passe " Grid.Column="0" Grid.ColumnSpan="2" Grid.Row="3" Margin="10,0,0,0"  />
                <PasswordBox Grid.Column="1" Grid.Row="3" Margin="25,5,25,5"  Password="{Binding Password,Mode= TwoWay}"/>
                <Button Grid.Column="1" Grid.Row="5" Content="Ouverture de session" Margin="25,10,25,1" Command="{Binding SeConnecterCommand}"/>
                <sdk:Label Content="Identifiant ou mot de passe invalide" Visibility="{Binding ErrLoginVisibility}" Grid.Column="1" HorizontalAlignment="Left" Height="28" Margin="10,10,0,0" Grid.Row="6" VerticalAlignment="Top" Foreground="Red"/>
                <CheckBox Content="Rester connecté" Grid.Column="1" HorizontalAlignment="Left" Margin="25,10,0,0" Grid.Row="4" VerticalAlignment="Top" IsChecked="{Binding RememberMe,Mode=TwoWay,UpdateSourceTrigger=PropertyChanged,TargetNullValue=False}"/>
            </Grid>
        </Border>



    </Grid>
</navigation:Page>
